import request from '@/router/axios';

export const getList = (params) => {
  return request({
    url: '/api/mes-product/statistics/product/pack/v2/tree',
    method: 'get',
    params: params
  });
};
export const getPackStatusList = () => {
  return request({
    url: '/api/blade-system/dict/dictionary?code=pack_status',
    method: 'get',
    params: {}
  });
};

export const getDetailList = (current, size, params) => {
  return request({
    url: '/api/mes-product/statistics/find-product-by-pack-id-page',
    method: 'get',
    params: {
      ...params,
      current,
      size
    }
  });
};

export const exportListData = (params) => {
  return request({
    url: '/api/mes-abacus/export/pack-product',
    method: 'post',
    data: params,
    responseType: 'blob'
  });
};
